package com.seaking.dao;

import com.seaking.pojo.School;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.orm.hibernate5.HibernateTemplate;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Created by wchha on 10/24 0024.
 */
@Repository
public class SchoolDao {

    @Autowired
    private HibernateTemplate hibernateTemplate;

    public List<School> getSchool() {
        List<School> schools = hibernateTemplate.loadAll(School.class);
        return schools;
    }

}
